<template>
  <div>
    <BasicInput ref="inputref"></BasicInput>
    {{ value }}
    <a-button @click="handleClick">聚焦</a-button>
    <a-button @click="getValue">获取值</a-button>
  </div>
</template>
<script lang="ts" setup>
import { BasicInput } from "/@/components";

import { ref } from "vue";
const inputref = ref<InstanceType<typeof BasicInput>>();
const value = ref("");
function handleClick() {
  inputref.value?.focus();
}
function getValue() {
  value.value = inputref.value?.getValue();
}
</script>
